import { createPinia } from "pinia" //引入pinia
import useUserInfoStore from './modules/useUserInfoStore'
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate' //引入持久化插件
 
const pinia = createPinia() //创建pinia实例
pinia.use(piniaPluginPersistedstate) //将插件添加到 pinia 实例上

export { useUserInfoStore } // 按需导出store模块 
export default pinia //导出pinia用于main.js注册